import React from 'react'
import { Provider } from 'react-redux'
import { ConnectedRouter } from 'react-router-redux'
import createHashHistory from 'history/createHashHistory'

import configureStore from '../config/configureStore'
import routes from '../route'

const history = createHashHistory()
const store = configureStore({})

export default () => (
	<Provider store={ store }>
		<ConnectedRouter history={history}>
      {routes}
    </ConnectedRouter>
	</Provider>
)